﻿@*@model List<ZP.DTO.Common.UserLoginDTO.CurrentUserAuthority>*@
@model List<ZP.DTO.fz_sys_menu.fz_sys_menuResultDTO>
@{
    ViewBag.Title = "LeftPage";
    Layout = null;
}

<!-- 侧 边 区 域 -->
<div class="layui-side layui-bg-black">
    <!-- 顶 部 图 标 -->
    <div class="layui-logo">
        <img class="logo"></img>
        <span class="title"></span>
    </div>
    <!-- 侧 边 菜 单 -->
    <div class="layui-side-scroll">
        <div id="sideMenu">

            <ul lay-filter="sideMenu" class="layui-nav arrow pear-menu layui-nav-tree pear-nav-tree">

                @if (Model != null && Model.Count > 0)
                {
                    int j = 0;
                    int k = 0;
                    foreach (var item in Model.Where(p => p.upId == 0))
                    {
                        <li class="layui-nav-item @(j == 0 ? "layui-nav-itemed" : "")">
                            <a href="javascript:;" menu-type="@item.isLeaf" menu-id="@item.id"><i class="layui-icon @(item.iconClass)"></i><span>@item.name</span><span class="layui-nav-more"></span></a>
                            <dl class="layui-nav-child">
                                @foreach (var childrenItem in Model.Where(p => p.upId == item.id))
                                {
                                    if (k == 0)
                                    {
                                        <dd class="layui-nav-itemed layui-this">
                                            <a class="site-demo-active" menu-type="1" menu-url="/Content/psi/img/welcome-bg.png" menu-id="1.1" menu-title="首页" menu-icon="layui-icon layui-icon-console" href="javascript:;">
                                                <i class="layui-icon layui-icon-console"></i><span>首页</span>
                                            </a>
                                        </dd>
                                    }
                                    <dd class="">
                                        <a class="site-demo-active" menu-type="@childrenItem.isLeaf" menu-url="@childrenItem.path" menu-id="@childrenItem.id" menu-title="@childrenItem.name" menu-icon="layui-icon layui-icon-console" href="javascript:;">
                                            <i class="layui-icon layui-icon-console"></i><span>@childrenItem.name</span>
                                        </a>
                                    </dd>
                                    k++;
                                }
                            </dl>
                        </li>
                        j++;
                    }
                }

                @*<li class="layui-nav-item layui-nav-itemed">
                        <a href="javascript:;" menu-type="0" menu-id="1"><i class="layui-icon layui-icon-console"></i><span>工作空间2</span><span class="layui-nav-more"></span></a>

                        <dl class="layui-nav-child">
                            <dd class="">
                                <a class="site-demo-active" menu-type="1" menu-url="/Home/Test" menu-id="14" menu-title="主页2" menu-icon="layui-icon layui-icon-console" href="javascript:;">
                                    <i class="layui-icon layui-icon-console"></i><span>主页2</span>
                                </a>
                            </dd>

                            <dd class="layui-nav-itemed layui-this">
                                <a class="site-demo-active" menu-type="1" menu-url="view/console/console1.html" menu-id="10" menu-title="控制后台" menu-icon="layui-icon layui-icon-console" href="javascript:;">
                                    <i class="layui-icon layui-icon-console"></i><span>控制后台</span>
                                </a>
                            </dd>

                            <dd>
                                <a class="site-demo-active" menu-type="1" menu-url="view/console/console2.html" menu-id="13" menu-title="数据分析" menu-icon="layui-icon layui-icon-console" href="javascript:;">
                                    <i class="layui-icon layui-icon-console"></i><span>数据分析</span>
                                </a>
                            </dd>
                        </dl>
                    </li>
                    <li class="layui-nav-item">
                        <a href="javascript:;" menu-type="0" menu-id="result"><i class="layui-icon layui-icon-auz"></i><span>结果页面</span><span class="layui-nav-more"></span></a>

                        <dl class="layui-nav-child">
                            <dd>
                                <a class="site-demo-active" menu-type="1" menu-url="view/result/success.html" menu-id="success" menu-title="成功" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;">
                                    <i class="layui-icon layui-icon-face-smile"></i><span>成功</span>
                                </a>
                            </dd>

                            <dd>
                                <a class="site-demo-active" menu-type="1" menu-url="view/result/error.html" menu-id="failure" menu-title="失败" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;">
                                    <i class="layui-icon layui-icon-face-cry"></i><span>失败</span>
                                </a>
                            </dd>
                        </dl>
                    </li>*@

                <!-- 多级 -->
                @*<li class="layui-nav-item">
                        <a href="javascript:;" menu-type="0" menu-id="component"><i class="layui-icon layui-icon-component"></i><span>常用组件</span><span class="layui-nav-more"></span></a>

                        <dl class="layui-nav-child">
                            <dd>
                                <a href="javascript:;" menu-type="0" menu-id="201">
                                    <i class="layui-icon layui-icon-console"></i><span>基础组件</span><span class="layui-nav-more"></span>
                                </a>
                                <dl class="layui-nav-child">
                                    <dd>
                                        <a class="site-demo-active" menu-type="1" menu-url="view/document/button.html" menu-id="2011" menu-title="功能按钮" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;">
                                            <i class="layui-icon layui-icon-face-smile"></i><span>功能按钮</span>
                                        </a>
                                    </dd>
                                    <dd><a class="site-demo-active" menu-type="1" menu-url="view/document/form.html" menu-id="2014" menu-title="表单集合" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>表单集合</span></a></dd>
                                    <dd><a class="site-demo-active" menu-type="1" menu-url="view/document/icon.html" menu-id="2010" menu-title="字体图标" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>字体图标</span></a></dd>
                                    <dd><a class="site-demo-active" menu-type="1" menu-url="view/document/select.html" menu-id="2012" menu-title="多选下拉" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>多选下拉</span></a></dd>
                                    <dd><a class="site-demo-active" menu-type="1" menu-url="view/document/tag.html" menu-id="2013" menu-title="动态标签" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>动态标签</span></a></dd>
                                </dl>
                            </dd>
                            <dd><a href="javascript:;" menu-type="0" menu-id="203"><i class="layui-icon layui-icon-console"></i><span>进阶组件</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/table.html" menu-id="2031" menu-title="数据表格" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>数据表格</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/step.html" menu-id="2032" menu-title="分布表单" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>分布表单</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/treetable.html" menu-id="2033" menu-title="树形表格" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>树形表格</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/dtree.html" menu-id="2034" menu-title="树状结构" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>树状结构</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/tinymce.html" menu-id="2035" menu-title="文本编辑" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>文本编辑</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/card.html" menu-id="2036" menu-title="卡片组件" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>卡片组件</span></a></dd></dl></dd>
                            <dd><a href="javascript:;" menu-type="0" menu-id="202"><i class="layui-icon layui-icon-console"></i><span>弹层组件</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/drawer.html" menu-id="2021" menu-title="抽屉组件" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>抽屉组件</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/notice.html" menu-id="2022" menu-title="消息通知" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>消息通知</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/loading.html" menu-id="2024" menu-title="加载组件" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>加载组件</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/popup.html" menu-id="2023" menu-title="弹层组件" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>弹层组件</span></a></dd></dl></dd>
                            <dd><a href="javascript:;" menu-type="0" menu-id="204"><i class="layui-icon layui-icon-console"></i><span>其他组件</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/hash.html" menu-id="2041" menu-title="哈希加密" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>哈希加密</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/iconPicker.html" menu-id="2042" menu-title="图标选择" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>图标选择</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/area.html" menu-id="2043" menu-title="省市级联" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>省市级联</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/count.html" menu-id="2044" menu-title="数字滚动" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>数字滚动</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/document/topBar.html" menu-id="2045" menu-title="顶部返回" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>顶部返回</span></a></dd></dl></dd>
                        </dl>
                    </li>
                    <li class="layui-nav-item"><a href="javascript:;" menu-type="0" menu-id="error"><i class="layui-icon layui-icon-face-cry"></i><span>错误页面</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/error/403.html" menu-id="403" menu-title="403" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>403</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/error/404.html" menu-id="404" menu-title="404" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>404</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/error/500.html" menu-id="500" menu-title="500" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>500</span></a></dd></dl></li>
                    <li class="layui-nav-item"><a href="javascript:;" menu-type="0" menu-id="system"><i class="layui-icon layui-icon-set-fill"></i><span>系统管理</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/user.html" menu-id="601" menu-title="用户管理" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>用户管理</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/role.html" menu-id="602" menu-title="角色管理" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>角色管理</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/power.html" menu-id="603" menu-title="权限管理" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>权限管理</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/deptment.html" menu-id="604" menu-title="部门管理" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>部门管理</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/logging.html" menu-id="605" menu-title="行为日志" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>行为日志</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/dict.html" menu-id="606" menu-title="数据字典" menu-icon="layui-icon layui-icon-face-cry" href="javascript:;"><i class="layui-icon layui-icon-face-cry"></i><span>数据字典</span></a></dd></dl></li>
                    <li class="layui-nav-item"><a href="javascript:;" menu-type="0" menu-id="common"><i class="layui-icon layui-icon-template-1"></i><span>常用页面</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="login.html" menu-id="701" menu-title="登录页面" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>登录页面</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/system/space.html" menu-id="702" menu-title="空白页面" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>空白页面</span></a></dd></dl></li>
                    <li class="layui-nav-item"><a href="javascript:;" menu-type="0" menu-id="echarts"><i class="layui-icon layui-icon-chart"></i><span>数据图表</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="view/echarts/line.html" menu-id="12121" menu-title="折线图" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>折线图</span></a></dd><dd><a class="site-demo-active" menu-type="1" menu-url="view/echarts/column.html" menu-id="121212" menu-title="柱状图" menu-icon="layui-icon layui-icon-face-smile" href="javascript:;"><i class="layui-icon layui-icon-face-smile"></i><span>柱状图</span></a></dd></dl></li>
                    <li class="layui-nav-item"><a href="javascript:;" menu-type="0" menu-id="code"><i class="layui-icon layui-icon-util"></i><span>开发工具</span><span class="layui-nav-more"></span></a><dl class="layui-nav-child"><dd><a class="site-demo-active" menu-type="1" menu-url="component/code/index.html" menu-id="801" menu-title="表单构建" menu-icon="layui-icon layui-icon-util" href="javascript:;"><i class="layui-icon layui-icon-util"></i><span>表单构建</span></a></dd></dl></li>*@
                <span class="layui-nav-bar" style="top: 28px; height: 0px; opacity: 0;"></span>
            </ul>

        </div>
    </div>
</div>